				
<%@ page pageEncoding="UTF-8"%>
<%@ taglib uri="http://java.sun.com/jsp/jstl/core" prefix="c"%>
<%@ taglib uri="http://java.sun.com/jsp/jstl/functions" prefix="fn"%>
<%@ taglib uri="http://java.sun.com/jsp/jstl/fmt" prefix="fmt"%>
<%@ taglib uri="http://www.ld.com/shield/tags" prefix="shield"%>
<%@ page trimDirectiveWhitespaces="true" %>
<fmt:setLocale value="zh_CN"/>
<shield:permssion type="button">
<%-- csrf参数 --%>
<shield:token></shield:token>
<table class="tab-list shield-table-odd shield-tr-status-class">
    <tr>
        <th class="w50 taCenter">序号</th>
	    <th>账号名称</th>
	    <th>有效期至</th>
	    <th>创建时间</th>
	    <th>修改时间</th>
        <th class="operate_icon">操作</th>
    </tr>
<c:forEach var="model" items="${pageBean.resultList }" varStatus="var">
    <tr status="${model.state }">
        <td style="text-align: center;">${(pageBean.currentPage -1)*pageBean.pageSize+var.count }</td>
        
	   	<td title="${model.accountName }">${model.accountName }<c:if test="${model.expired }"><span class="tips">[已过期]</span</c:if></td>
		<!-- 增加样式shieldDatetime -->
	   	<td ><span class="shieldDatetime">${model.dateUntil }</span></td>
	   	<td ><fmt:formatDate value="${model.createTime }" pattern="yyyy-MM-dd HH:mm:ss"/></td>
	   	<td ><fmt:formatDate value="${model.updateTime }" pattern="yyyy-MM-dd HH:mm:ss"/></td>
	
        <td>
        	<!-- href改为data-url -->
            <a data-url="${ctxPathA}/usercenter/sysusertemp/show" shieldParams="{'id':'${model.id }'}" class="shieldDialog shield-icon show" viewTitle="临时账号详情" data-icon-title="查看临时账号详情"
               viewWidth="450"></a>
            <a data-url="${ctxPathA}/usercenter/sysusertemp/toAddOrUpdate" shieldParams="{'id':'${model.id }'}"  class="shieldDialog shield-icon update" viewTitle="修改临时账号" data-icon-title="修改临时账号"
               viewWidth="450"></a>
	<c:if test="${model.state != 2 }">
		  	<a data-url="${ctxPathA }/usercenter/sysusertemp/disable" shieldParams="{'id':'${model.id }'}" class="shieldAjax shield-icon disable" viewTitle="确定要停用该用户吗?"></a>
	</c:if>
	<c:if test="${model.state == 2 }">
		  	<a data-url="${ctxPathA }/usercenter/sysusertemp/enable" shieldParams="{'id':'${model.id }'}" class="shieldAjax shield-icon enable" viewTitle="确定要启用该用户吗?"></a>
	</c:if>
            <%-- <a data-url="${ctxPathA}/usercenter/sysusertemp/del" shieldParams="{'id':'${model.id }'}"  class="shieldAjax shield-icon del" viewTitle="确定要删除该条记录吗?"></a> --%>
        	<!-- href改为data-url -->
            <a data-url="${ctxPathA}/usercenter/sysusertemp/toSearchLog" shieldParams="{'id':'${model.id }'}" class="shieldDialog " viewTitle="临时账号日志" 
               viewWidth="800"><img src="${ctxPath }/images/icon/shuju.png" title="查看临时账号日志"/></a>
        </td>
    </tr>
</c:forEach>
<c:if test="${empty pageBean.resultList }">
    <!-- 无数据时展示，有数据时展示上面的列表, nodatatr_plugin自动处理列合并数-->
    <tr class="nodatatr_plugin">
        <td colspan="6" class="taCenter">暂无数据</td>
    </tr>
</c:if>
</table>
</shield:permssion>
<%@include file="/WEB-INF/view/a/include/pagination.jsp"%>
